import React, { Component } from "react";

export default class RefOld extends Component {
  clickHandle = () => {
    console.log(this);
    console.log(this.refs.inputRef);
    this.refs.inputRef.focus();
  };

  render() {
    return (
      <div>
        <h2>过时的ref 已经移除了</h2>
        {/* <input type="text" ref="inputRef" /> */}
        <button onClick={this.clickHandle}>聚焦</button>
      </div>
    );
  }
}
